package com.syh.jn.scm.infrastructure.repository.model.base;

import com.syh.core.ddd.infrastructure.repository.model.SuperBusinessModel;
import lombok.*;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * 运营项目
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@Entity
@Table(name = "T_BASE_PROJECT")
@EqualsAndHashCode(callSuper = true)
public class ProjectModel extends SuperBusinessModel {
  /**
   * 状态（-1：停用 1：启用）
   */
  @Column(name = "STATUS", columnDefinition = "smallint COMMENT '状态（-1：停用 1：启用）'")
  private Short status;
  /**
   * 上级项目id
   */
  @Column(name = "SUP_ID", columnDefinition = "bigint COMMENT '上级项目id'")
  private Long supId;
  /**
   * 目录树    格式：1-11-12  1：父父类id，11：父类id，12：当前id
   */
  @Column(name = "CATALOG_CODE", columnDefinition = "varchar(50) COMMENT '目录树'")
  private String catalogCode;
  /**
   * 项目编码
   */
  @Column(name = "CODE", columnDefinition = "varchar(50) COMMENT '项目编码'")
  private String code;
  /**
   * 项目名称
   */
  @Column(name = "NAME", columnDefinition = "varchar(50) COMMENT '项目名称'")
  private String name;
  /**
   * 排序等级
   */
  @Column(name = "ORDER_LEVEL", columnDefinition = "int COMMENT '排序等级'")
  private Integer orderLevel;
  /**
   * 描述
   */
  @Column(name = "DESCRIPTION", columnDefinition = "varchar(100) COMMENT '描述'")
  private String description;
  /**
   * 创建日期
   */
  @Column(name = "CREATE_TIME_STAMP", columnDefinition = "bigint COMMENT '创建日期'")
  private Long createTimeStamp;
  /**
   * 最后修改日期
   */
  @Column(name = "LAST_UPDATE_TIME_STAMP", columnDefinition = "bigint COMMENT '最后修改日期'")
  private Long lastUpdateTimeStamp;
}
